package cn.brian.modular.log.controller;

import cn.brian.framework.log.LogAnnotation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.io.IOException;
import java.util.ArrayList;
import java.util.List;

/**
 * @author huangjinghua
 * @date 2020/6/5 10:35
 */
@RestController
@RequestMapping("/log")
@Slf4j
public class LogController {

    @GetMapping("/query")
    @LogAnnotation(module="log-center")
    public List queryList(String id) throws Exception, IOException {
        log.info("调用服务");
        List  list=new ArrayList();
        list.add("2222");
        list.add("1111");
        list.add("3333");
        list.add("4444");
        list.add("5555");
        return list;
    }
}
